import os
from datetime import datetime

TXT_PATH = "/Users/aiqikeji/Documents/workspace_python/run_log/learn_start_time.txt"

file = open(TXT_PATH, 'a+')

class RunTimeFileRecorder:
    @staticmethod
    def record():
        now = datetime.now()
        formatted_date = now.strftime('%Y-%m-%d %H:%M:%S')
        file.write("{date}\n".format(date=formatted_date))
        file.flush()